//
//  LogInPassWordTableViewCell.m
//  EasyToTesco2.0
//
//  Created by 袖手旁觀 on 16/6/17.
//  Copyright © 2016年 EasyToTesco. All rights reserved.
//

#import "LogInPassWordTableViewCell.h"

#define LeftMargin 8

@implementation LogInPassWordTableViewCell

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
    if (self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]) {
        [self setUpLogInPassWordCell];
    }
    return self;
}

- (void)setUpLogInPassWordCell {
    
    UILabel *firstCellLabel = [[UILabel alloc] init];
    firstCellLabel.text = @"18000000000";
    firstCellLabel.font = [UIFont systemFontOfSize:16];
    firstCellLabel.textAlignment = NSTextAlignmentLeft;
    firstCellLabel.hidden = YES;
    self.firstCellLabel = firstCellLabel;
    [self.contentView addSubview:firstCellLabel];
    
    UITextField *textField = [[UITextField alloc] init];
    textField.borderStyle = UITextBorderStyleNone;
    textField.font = [UIFont systemFontOfSize:14];
    textField.keyboardType = UIKeyboardTypeNumberPad;
    textField.hidden = YES;
    self.otherTextField = textField;
    [self.contentView addSubview:textField];
    
    [firstCellLabel mas_makeConstraints:^(MASConstraintMaker *make) {
        make.centerY.equalTo(self.mas_centerY);
        make.left.equalTo(self.mas_left).with.offset(LeftMargin * 3);
        make.width.mas_equalTo(self.width/2);
        make.height.mas_equalTo(self.Height);
    }];
    
    [textField mas_makeConstraints:^(MASConstraintMaker *make) {
        make.centerY.equalTo(self.mas_centerY);
        make.left.equalTo(self.mas_left).with.offset(LeftMargin * 3);
        make.width.mas_equalTo(self.width/2);
        make.height.mas_equalTo(self.Height);
    }];
    
}

@end
